
#ifndef _TTG_SERVICES_TASKSCHEDULER_TASKSCHEDULERSETTINGS_
#define _TTG_SERVICES_TASKSCHEDULER_TASKSCHEDULERSETTINGS_
#include "Common/Definitions.h"

#include "Runtime.Low/Services/ServiceSettings.h"

namespace ttg
{
	namespace services
	{
		//Contains settings for TaskScheduler service.
		class TaskSchedulerSettings :public ttg_internal::services::ServiceSettings
		{
			private:
				int worker_count;
			public:
				//Creates default settings: count of workers is equal to core count.
				inline TaskSchedulerSettings()
					:ttg_internal::services::ServiceSettings("TaskScheduler")
				{ worker_count = 0; }
				//Sets required count of workers.
				inline void setWorkerCount(int worker_count)
				{ this->worker_count = worker_count; }
				//Returns requred count of workers.
				inline int getWorkerCount() const
				{ return worker_count; }
				//Serializes current settings.
				virtual std::string serialize();
				//Deserialized settings. Never throws ttg::Error().
				static TaskSchedulerSettings deSerialize(const char *value);
		};
	}
}

#endif
